1. Field of the Invention
The present invention relates generally to the management of data files, such as large object binary files, for temporary access by a requesting application.
2. Relevant Technology
Databases are computerized information storage and retrieval systems. A Relational Database Management System (RDBMS) is a database system which uses relational techniques for storing and retrieving data. Relational databases are organized into tables of rows and columns of data. A database typically includes many tables, and each table includes multiple rows and columns. The tables are conventionally stored in direct access storage devices (DASD), such as magnetic or optical disk drives, for semi-permanent storage.
Users communicate with an RDBMS using a Structured Query Language (SQL) interface. The SQL interface allows users to create, manipulate, and query a database by formulating relational operations on the tables, either interactively, in batch files, or embedded in host languages such as C and COBOL. SQL has evolved into a standard language for RDBMS software and has been adopted as such by both the American National Standards Institute (ANSI) and the International Standards Organization (ISO).
A common application for databases relates to their interaction with Internet web browsers. In responding to a web browser query, a table may need to be created on the web browser. This requires the transfer of data files and the formatting of a table on the web browser. As the database is responsive to SQL and a web browser requires an HTML format, an interface module is required to enable interaction between the web browser and the database. One example of such a interface module is Net.Data available from IBM Corp., Armonk, N.Y.
Net.Data enables Internet and intranet access to relational data on a variety of platforms. Net.Data incorporates a marcrolanguage which supports both HTML and SQL and allows for interaction with universal web browsers and relational database systems. Net.Data operates in conjunction with a web server interface and supports client-side processing as well as server-side processing with languages such as Java, REXX, Perl and C++. Net.Data provides database connectivity to a variety of data sources including information stored in relational databases and flat files. Net.Data may support a variety of operating systems, including OS/2, AIX, Windows NT, HP-UX, Solaris, SCO, OS/390 and OS/400. Net.Data is further able to cache web pages to improve application performance, particularly when repeated requests are made for the same web page. Although the invention is compatible for use with an interface module such as Net.Data other common gateway interface applications may be used with the present invention as well.
The interface module, which may be resident on a server, receives a query from a web browser and formats the query into SQL and interacts with the database to create the table. The interface module then uses its macrolanguage to present the table to the web browser in HTML format. The web browser, in turn, displays the table to a remote user. In this manner, the interface module serves as an Internet gateway for accessing a database.
In creating and formatting a table, the interface module retrieves files from the database for inclusion in the table. Small files, such as character values, may be passed directly from the database, converted into HTML format, and displayed on the browser. However, large files such as large object binary files (LOBs) are difficult to pass directly. A necessary feature of the interface module, such as found in Net.Data, is the ability to retrieve and incorporate LOBs into HTML format. A LOB may be a picture file, a video file, an audio file, as well as executable code. A LOB may be stored in the database and the database may extend across one or more servers. In accessing a LOB, a datalink may be used to point to actual location of the LOB.
Rather than passing LOBs directly to the web browser directly, the LOBs are stored in a temporary directory, commonly termed a “tmpblobs directory.” The temporary directory is termed such because it must store LOBs for a short duration, such as for a web session. The temporary directory is a public directory which may be resident on the server side and is accessible by a web server. The web browser is only able to view files which the web server makes public to a web browser. Thus, the web browser does not have access to the database and must go through web server to access files in a public directory. A representation or link of a LOB is incorporated into the HTML document. As the table is generated on the web browser, the web server retrieves LOBs from the temporary directory.
In order to accommodate numerous web browsers, multiple applications of an interface module may be running. Each interface module may store numerous LOBs to satisfy requests from the web browsers. Given the volume of potential Internet use and the size of LOBs, a temporary directory may rapidly fill up even relatively large memory devices. Full temporary directories would no longer be accessible and would prevent the retrieval and use of additional LOBs. Furthermore, because the temporary directory is a public directory, a hacker may be able to access LOBs in the temporary directory, which are stored in the temporary directory beyond a reasonable time.
Periodic deletions of LOBs in the temporary directory are required to free up space and to reduce the opportunity for unauthorized viewing. Ideally, LOBs actively displayed on a web browser should not be deleted. Premature deletions may be avoided by shutting down the web server, but this prevents access to and use of the web site. A web site must be constantly accessible to accommodate the large number of users and to encourage its use. In some instances, shutting down a web site even momentarily may produce devastating consequences to users.
Thus, it would be an advancement in the art to provide a system and method for automatically removing LOBs to increase space in a temporary directory.
It would be a further advancement in the art to reduce the likelihood of deleting active LOBs without shutting down a web server.
Such an invention is disclosed and claimed herein.